package com.vogue.supplymall.admin.business.domain.biz.impl;

import com.vogue.supplymall.admin.business.controller.AdminHomePageController;
import com.vogue.supplymall.admin.business.domain.biz.AdminHomePageBiz;
import com.vogue.supplymall.match.domain.service.MatchOrganService;
import com.vogue.supplymall.shop.domain.service.ShopService;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;

/**
 * The type Admin home page biz.
 *
 * @aouthor: zhangliang
 * @date: Create in 2018-04-24
 */
@Service("adminHomePageBiz")
public class AdminHomePageBizImpl implements AdminHomePageBiz {
    public static final Logger LOGGER_ADMINHOMEPAGEBIZIMPL = LoggerFactory.getLogger(AdminHomePageController.class);
    @Resource
    private ShopService shopService;
    @Resource
    private MatchOrganService matchOrganService;

    @Override
    public Long countValidShop() {
        LOGGER_ADMINHOMEPAGEBIZIMPL.info("service method countValidShop()");
        return shopService.countValidShop();
    }

    @Override
    public Long countValidOrgan() {
        LOGGER_ADMINHOMEPAGEBIZIMPL.info("service method countValidOrgan()");
        return matchOrganService.countValidOrgan();
    }
}
